package org.example.classdemo.finaldemo;

import lombok.Data;

/**
 * class加上final修饰则其他类无法继承,从而避免改变类的行为
 */
@Data
public final class StoneApple {

    public StoneApple(String name,String color){
        this.name = name;
        this.color = color;
    }
    private final String name;
    private final String color;
}
